div(layout="column", class="md-whiteframe-1dp")
	div(id="header")
		// Tool bar
		md-toolbar(class="md-primary" flex)
			.md-toolbar-tools
				span.panel-icon(aria-label="Status", ng-click="vm.hideItem()")
					md-icon.angular-material-icons( flex="none") {{vm.statusIcon}}
				span(ng-if="!vm.showFilter" flex="50")
					h2
						span {{vm.contentData.title}}
				#filterContainer(flex)
					panel-card-filter(
						ng-if="vm.hasFilter()"
						show-filter='vm.showFilter'
						filter-text='vm.filterText')

				div(flex, ng-if="!vm.showFilter")

				// Options
				#options(layout="row")

		panel-card-chips-filter(id="chips-filter"
								ng-show="vm.chipsFilterVisible && !vm.hideMenuButton"
								chips="vm.chipsFilterChips"
								suggestions="vm.chipsFilterSuggestions"
								place-holder=" Filter"
								show-filter="vm.chipsFilterVisible"
							)

	// Card content
	#panelCardContainer
		// Content
		md-content(id="content", style="height:{{vm.contentData.height}}px")
			issues(
				ng-if="vm.contentData.type === 'issues'"
				account='vm.account'
				model='vm.model'
				show-add='vm.showAdd'
				show='vm.contentData.show'
				on-content-height-request='vm.onContentHeightRequest(height)'
				on-show-item='vm.showItem()'
				hide-item='vm.hideSelectedItem'
				show-edit='vm.showEdit'
				branch='vm.branch'
				model-settings='vm.modelSettings'
				revision='vm.revision'
				selected-objects='vm.selectedObjects'
				set-initial-selected-objects='vm.setInitialSelectedObjects({selectedObjects: selectedObjects})'
				filter-chips="vm.chipsFilterChips"
				selected-menu-option='vm.selectedMenuOption')

			risks(
				ng-if="vm.contentData.type === 'risks'"
				account='vm.account'
				model='vm.model'
				show-add='vm.showAdd'
				show='vm.contentData.show'
				on-content-height-request='vm.onContentHeightRequest(height)'
				on-show-item='vm.showItem()'
				hide-item='vm.hideSelectedItem'
				show-edit='vm.showEdit'
				branch='vm.branch'
				model-settings='vm.modelSettings'
				revision='vm.revision'
				selected-objects='vm.selectedObjects'
				set-initial-selected-objects='vm.setInitialSelectedObjects({selectedObjects: selectedObjects})'
				filter-chips="vm.chipsFilterChips"
				selected-menu-option='vm.selectedMenuOption')

			groups(
				ng-if="vm.contentData.type === 'groups'"
				account='vm.account'
				model='vm.model'
				revision='vm.revision'
				on-show-item='vm.showItem()'
				on-hide-item='vm.hideItem()'
				hide-item='vm.hideSelectedItem'
				on-content-height-request='vm.onContentHeightRequest(height)'
				model-settings='vm.modelSettings'
				show-filter="vm.showFilter"
				filter-text='vm.filterText'
				selected-menu-option='vm.selectedMenuOption')

			viewpoints(
				ng-if="vm.contentData.type === 'viewpoints'"
				account='vm.account'
				model='vm.model'
				revision='vm.revision'
				on-show-item='vm.showItem()'
				on-hide-item='vm.hideItem()'
				hide-item='vm.hideSelectedItem'
				on-content-height-request='vm.onContentHeightRequest(height)'
				model-settings='vm.modelSettings'
				show-filter="vm.showFilter"
				filter-text='vm.filterText')

			docs(
				ng-if="vm.contentData.type === 'docs'"
				show-add='vm.showAdd'
				show='vm.contentData.show'
				on-content-height-request='vm.onContentHeightRequest(height)'
				on-show-item='vm.showItem()'
				hide-item='vm.hideSelectedItem'
				show-edit='vm.showEdit'
				account='vm.account'
				model='vm.model'
				branch='vm.branch'
				model-settings='vm.modelSettings'
				revision='vm.revision'
				selected-objects='vm.selectedObjects'
				set-initial-selected-objects='vm.setInitialSelectedObjects({selectedObjects: selectedObjects})')

			tree(
				ng-if="vm.contentData.type === 'tree'"
				show-add='vm.showAdd'
				show='vm.contentData.show'
				on-content-height-request='vm.onContentHeightRequest(height)'
				on-show-item='vm.showItem()'
				hide-item='vm.hideSelectedItem'
				show-edit='vm.showEdit'
				account='vm.account'
				model='vm.model'
				branch='vm.branch'
				model-settings='vm.modelSettings'
				revision='vm.revision'

				selected-objects='vm.selectedObjects'
				set-initial-selected-objects='vm.setInitialSelectedObjects({selectedObjects: selectedObjects})'
				show-filter="vm.showFilter"
				filter-text='vm.filterText'
				selected-menu-option='vm.selectedMenuOption')

			compare(
				model-settings='vm.modelSettings'
				on-content-height-request='vm.onContentHeightRequest(height)'
				account='vm.account'
				revision='vm.revision'
				model='vm.model'
				ng-if="vm.contentData.type === 'compare'")

			gis(
				account='vm.account'
				model='vm.model'
				on-content-height-request='vm.onContentHeightRequest(height)'
				model-settings='vm.modelSettings'
				ng-if="vm.contentData.type === 'gis'")


	// Help icon and tool tip
	div(ng-if="vm.showHelp")
		md-button.md-fab.md-mini#helpButton(aria-label="Help")
			md-icon(md-font-icon="fa-question", class="fa")
			md-tooltip(md-direction="top") {{vm.contentData.help}}
